package com.github.shuaidd.web.conf;

import org.activiti.app.model.component.SimpleContentTypeMapper;
import org.activiti.app.service.api.UserCache;
import org.activiti.app.service.editor.BpmnDisplayJsonConverter;
import org.activiti.app.service.editor.ModelImageService;
import org.activiti.app.service.idm.UserCacheImpl;
import org.activiti.app.service.runtime.ActivitiService;
import org.activiti.app.service.runtime.RelatedContentStreamProvider;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;

/**
 * 描述
 *
 * @author ddshuai
 * @date 2020-07-17 12:33
 **/
@Configuration
public class LwfConfiguration {

    @Bean
    public UserCache userCache() {
        return new UserCacheImpl();
    }

    @Bean
    public ModelImageService modelImageService(){
        return new ModelImageService();
    }

    @Bean
    public BpmnDisplayJsonConverter bpmnDisplayJsonConverter(){
        return new BpmnDisplayJsonConverter();
    }

    @Bean
    public SimpleContentTypeMapper simpleContentTypeMapper(){
        return new SimpleContentTypeMapper();
    }

    @Bean
    public ActivitiService activitiService(){
        return new ActivitiService();
    }

    @Bean
    public RelatedContentStreamProvider relatedContentStreamProvider(){
        return new RelatedContentStreamProvider();
    }
}
